<?php
/*****************************************************************************
 *              Projet Master RIM : Reconnaissance de panneaux               *
 *                    Guillaume MONTAVON & Renaud DAVID                      *
 *                                                                           *
 *             Page web permettant de valider ou non un panneau              *
 *****************************************************************************/

include_once("header.inc.php");

?>

	<script type="text/javascript" src="js/validation.js"></script>
	
	<h1>Panneaux à valider et à classer</h1>
	
	<fieldset class="boite_bleu">
		
		<div id="listePanneau" style="display:inline-block;"></div>
		
		<div id="validerDoublon" style="display:inline-block;margin-left:40px;">
			<center><label for="gardeImage">Garder l'image :</label></center>
			<br/>
			<input type="radio" name="gardeImage" value="0" style="float:left;" />
			<input type="radio" name="gardeImage" value="1" style="float:right;" checked="checked"/>
			<br/><br/><br/>
			
			<input id="idPanneauDoublon" type="hidden" name="idPanneauDoublon" value="0">
			<center><button type="button" id="boutonValiderDoublon">Fusionner les 2 panneaux</button></center>
		</div>
		<div id="doublonPanneau" style="display:inline-block;margin-left:40px;"></div>
		
		<form class="cmxform" id="validationForm" method="post" action="requete.php?objet=validerPanneau">
			
			<input id="validationIdPanneau" type="hidden" name="idPanneau" value="0">
			
			<div id="contenuImgAValider"></div>
			<br/><br/>
			
			<div style="width: 20%;display: inline-block;">
			
			<label for="fiabilite">Fiabilité</label>
			<input id="fiabilite" name="fiabilite" type="text" class="required" value="1" />
			<label for="type">Type</label>
			<select id="type" name="type" class="required" onchange="MAJImgType();">
				<option value="0">Type de panneau : </option>
				<?php
					$req = "SELECT * FROM typepanneau";
					$resPan = mysql_query($req);
					while($type = mysql_fetch_array($resPan))
						echo '<option value="'.$type['idType'].'">'.$type['libelleType'].'</option>';
				?>
			</select><br/><br/><br/>
			
			</div>
			
			<div id="typeImage" style="width: 60%;display: inline-block;"></div>
			
			<center><button type="button" id="supprimerPanneau">Supprimer</button>&nbsp;&nbsp;&nbsp;<button class="submit" type="submit" id="validerPanneau">Valider</button></center>
			
		</form>
		
	</fieldset>
	
<?php

include_once("footer.inc.php");

?>